package com.ruoyi.selectionRecords.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.selectionRecords.mapper.UoocCourseSelectionMapper;
import com.ruoyi.selectionRecords.domain.UoocCourseSelection;
import com.ruoyi.selectionRecords.service.IUoocCourseSelectionService;

/**
 * 选课记录Service业务层处理
 * 
 * @author LGJ
 * @date 2025-07-08
 */
@Service
public class UoocCourseSelectionServiceImpl implements IUoocCourseSelectionService 
{
    @Autowired
    private UoocCourseSelectionMapper uoocCourseSelectionMapper;

    /**
     * 查询选课记录
     * 
     * @param recordId 选课记录主键
     * @return 选课记录
     */
    @Override
    public UoocCourseSelection selectUoocCourseSelectionByRecordId(Long recordId)
    {
        return uoocCourseSelectionMapper.selectUoocCourseSelectionByRecordId(recordId);
    }

    /**
     * 查询选课记录列表
     * 
     * @param uoocCourseSelection 选课记录
     * @return 选课记录
     */
    @Override
    public List<UoocCourseSelection> selectUoocCourseSelectionList(UoocCourseSelection uoocCourseSelection)
    {
        return uoocCourseSelectionMapper.selectUoocCourseSelectionList(uoocCourseSelection);
    }

    /**
     * 新增选课记录
     * 
     * @param uoocCourseSelection 选课记录
     * @return 结果
     */
    @Override
    public int insertUoocCourseSelection(UoocCourseSelection uoocCourseSelection)
    {
        return uoocCourseSelectionMapper.insertUoocCourseSelection(uoocCourseSelection);
    }

    /**
     * 修改选课记录
     * 
     * @param uoocCourseSelection 选课记录
     * @return 结果
     */
    @Override
    public int updateUoocCourseSelection(UoocCourseSelection uoocCourseSelection)
    {
        return uoocCourseSelectionMapper.updateUoocCourseSelection(uoocCourseSelection);
    }

    /**
     * 批量删除选课记录
     * 
     * @param recordIds 需要删除的选课记录主键
     * @return 结果
     */
    @Override
    public int deleteUoocCourseSelectionByRecordIds(Long[] recordIds)
    {
        return uoocCourseSelectionMapper.deleteUoocCourseSelectionByRecordIds(recordIds);
    }

    /**
     * 删除选课记录信息
     * 
     * @param recordId 选课记录主键
     * @return 结果
     */
    @Override
    public int deleteUoocCourseSelectionByRecordId(Long recordId)
    {
        return uoocCourseSelectionMapper.deleteUoocCourseSelectionByRecordId(recordId);
    }
}
